package com.tuanzi.loan.business.service.extratemplate;

import com.tuanzi.loan.business.entity.extratemplate.ExtraTemplate;
import com.tuanzi.loan.business.entity.extratemplate.ExtraTemplateSpecial;
import com.tuanzi.loan.core.service.BaseAuditService;
import com.tuanzi.loan.core.vo.PageSearcher;
import com.tuanzi.loan.vo.request.extratemplate.ExtraTemplateRequest;
import com.tuanzi.loan.vo.response.extratemplate.ExtraTemplateResponse;
import org.springframework.data.domain.Page;

import java.util.List;

/**
 * @author caiwanlin
 * @create 2018-10-16 14:35
 */
public interface ExtraTemplateService extends BaseAuditService<ExtraTemplate,Long> {
    Page<ExtraTemplateResponse> list(PageSearcher<ExtraTemplateRequest> pageSearcher);

    void onSave(ExtraTemplate extraTemplate, List<ExtraTemplateSpecial> specialList) throws Exception;

    int countAllByTemplateId(Integer templateId);

    void deleteExtraTemplateCache(Integer templateId);
}
